#!/bin/bash
# 多选项参数，采用getopts/getopt处理传入的参数



   
while getopts "a:c::" opt; do  
  case $opt in  
    a)  
      echo "this is -a the arg is ! $OPTARG"   
      ;; 
    c)
      echo "this is -c the arg is : $OPTARG"
      ;;
    \?)  
      echo "Invalid option: -$OPTARG"   
      ;; 
  esac 
done
